﻿using System.Reflection;
using System.IO;

namespace ContentRenderingApiSystemTest.Helper
{
    internal static class ResourceHelper
    {
        internal static string FetchString(string typeFullName)
        {
            Assembly assembly = Assembly.GetExecutingAssembly();

            using (Stream stream = assembly.GetManifestResourceStream(typeFullName))
            {
                using (TextReader textReader = new StreamReader(stream))
                {
                    return textReader.ReadToEnd();
                }
            }
        }
    }
}
